using System;
class rohit
{
    string name;
    int age;
    char choice;
    public void accept()
    {
        Console.WriteLine("Enter your name");
        name = Console.ReadLine();

        Console.WriteLine("Enter your age");
        age = Convert.ToInt32(Console.ReadLine());
        for (int i = 0; i <= 4; i++)
        {

            Console.WriteLine("1. About chapter \t2. Access specifier\n3. Summary\t\t4. Exercises\n5. Practice questions");
            Console.WriteLine("User select any choice");
            choice = Convert.ToChar(Console.ReadLine());



            switch (choice)
            {
                case '1':
                    {
                        Console.WriteLine("\n1. In c# we heaving five featurees\na. Abstraction\nb. Encapsulation\nc. Poly morphism\nd. Inheritance\ne. Threading");
                        Console.WriteLine("\n2. (1) Abstraction--- Abstraction means involves extracting \nonly relevent information.\n\n(2) Encapsulation---Encapsulation means to enclose \n   in or as if in a capsule.");
                        Console.WriteLine("\n3. C# access specifier\na. Public\nb. Private\nc. Protected\nd. Internal\ne. Protected internal");
                        Console.WriteLine("\n4. Methods (use for devide the program)\n(1) Define method.\n(2) Call method");
                        Console.WriteLine("\n5. Methods type\n(a) Simple methods\n(b) Parameterized methods");

                        Console.WriteLine("\nYour name is : {0} Your age is: {1}", name, age);
                        Console.WriteLine("\nThanks for using program");
                        break;
                    }

                case '2':
                    {
                        Console.WriteLine("\n1. Public access specifier----\n\t Use within one and outside the classes.\n\n2. Private access specifier----\n\t Use within one class\n\n3. Protected access specifier----\n\t Use in inheritance\n\n4. Internal access specifier----\n\t Use within one application\n\n5. Protected internal----\n\t Use wihin one application and\n\tin inheritance");
                        Console.WriteLine("\nYour name is : {0} Your age is: {1}", name, age);
                        Console.WriteLine("\nThanks for using program");
                        break;
                    }
                case '3':
                    {
                        Console.WriteLine("\nIn this chapter, you learned that:");
                        Console.WriteLine("\n1. Abstraction is the process of reducing information \ncontent in order to retain only the relevant information\n for a particular purpose.");
                        Console.WriteLine("\n2. Encapsulation is the process of hiding all the details \nof an object that do not contribute to its essential characteristics.");
                        Console.WriteLine("\n3. An access specifier is used to determine whether any \nother class or function can access the member variable and functions\n of a particular class.");
                        Console.WriteLine("\n4. The public access specifier allows a class to expose \nits member variables and member functions to other functions and objects.");
                        Console.WriteLine("\n5. The private access specifier allows a class to hide its \nmember variables and members functions from other class functions and objects.");
                        Console.WriteLine("\n6. The protected access specifier allows a class to hide\n its member variables and member functions from other class objects and\n functions, just like the private access specifier while \nimplementing inheritance.");
                        Console.WriteLine("\n7. A method is a set of one or more program statements \nthat can be executed by referring to the method name.");
                        Console.WriteLine("\n8. Defining a method means declaring the elements of its structure.");
                        Console.WriteLine("\n9. The access modifiers that can be passed into and out of \na method. When you define a method, you can include a list of parameters \nin parentheses.");
                        Console.WriteLine("\n10. Parameters can be passed by using any one of the following\n parameters types:\n\t(1) Value\n\t(2) Referance\n\t(3) Output");
                        Console.WriteLine("\n11. Pass by value is the default mechanism for passing \npaameters in C#.");
                        Console.WriteLine("\n12. A referance parameter is a referance to a memory \nlocation of a data number.");
                        Console.WriteLine("\n13. Output parameters are like referance parameters, except \nthat they transfer data out of the method rather than into it.");
                        Console.WriteLine("\n14. The return statement retains its value even after the \nfunction to which it belongs has been ececuted.");
                        Console.WriteLine("\n15. The static variable retains its value even after the \nfunction to which it belongs has been executed.");
                        Console.WriteLine("\n16. The static functions can access only static variables. \nnon-static variables cannot be accessed by using static functions.");
                        Console.WriteLine("\nYour name is : {0} Your age is: {1}", name, age);
                        Console.WriteLine("\nThanks for using program");
                        break;
                    }
                case '4':
                    {
                        Console.WriteLine("\nEXERCISE 1\nWrite a program that emulates a calculator. The \ncalculator should consist of the following methods:\n\t Addition\n\tSubstraction\n\tMultipication\n\tDivision\nEach method should have a minimum of two parameters.");
                        Console.WriteLine("\nEXERCISE 2\nWrite a program to identify the greatest number \nentered by a user. Create this program by using methods.");
                        Console.WriteLine("\nEXERCISE 3\nWrite a program to calculate the factorial of the\n number entered by a user. Create this program by using static \nfunctions and static variables.\n\nHint: The limit of users input should be 1-20");
                        Console.WriteLine("\nEXERCISE 4\nInformation Technologies is a software development \norganisation. Annie a software developer of the organization is currently\n under a project of cineplexes. She has to develop a program that counts the\n number of tickets sold. If a ticket is not sold,the \nprogram should give the following messages \n``You should sell the tickets``");
                        Console.WriteLine("\nYour name is : {0} Your age is: {1}", name, age);
                        Console.WriteLine("\nThanks for using program");
                        break;
                    }
                case '5':
                    {
                        Console.WriteLine("\nQ.1 State whether the given statement is true or false.\nEncapsulation means preventing access to nonessential details.\n\nAns. True");
                        Console.WriteLine("\nQ.2 Consider the following statements:\nStatement A: Static variables retain their values\neven after the function to which they\nbelong has been executed.\n\nStatement B: Static functions can access static as well \nas non-static variables.\n\nWhich of the given statements are true?\na. A & B both are true.\nb. A is true & B is false.\nc. A is false & B is true.\nd. A & B both are false.\n\n\nAns. A is true & B is false.");
                        Console.WriteLine("\nQ.3 Which of the following statement about access Vspecifier is true?\n\na. An access specifier determines which features of a class can\n be used by other classes.\n\nb. Protected variables are not accessible to the subclasses of \nthe class in which they are declared.\nc. A method declared as public in a superclass cannot be \naccessed by the subclasses of that superclass.\nd. A variable declared inside a method can have access specifier.\n\n\nAns. A");
                        Console.WriteLine("\nQ.4 State whether the following statement is true or false.\n\nIn a public access specifier, all the public members of \nthe base class become protected.\n\n\nAns. False");
                        Console.WriteLine("\nQ.5 State whether the given statement is true or false.\n\nAbstraction represents the essential characteristics \nof an object or classes that differentiate it from \nobjects or classes.\n\n\nAns. True");
                        break;
                    }

                default:
                    {
                        Console.WriteLine("\nChoose Correct Option");
                        Console.WriteLine("\nYour name is : {0} Your age is: {1}", name, age);
                        Console.WriteLine("\nThanks for using program");
                        break;
                    }
            }
        }


    }

    public static void Main()
    {
        rohit oo = new rohit();
        oo.accept();
        Console.ReadLine();
    }

}

